-
Notifications
You must be signed in to change notification settings - Fork 1.6k
/
Tuple`5.xml
1143 lines (1026 loc) · 76.7 KB
/
Tuple`5.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
<Type Name="Tuple<T1,T2,T3,T4,T5>" FullName="System.Tuple<T1,T2,T3,T4,T5>">
<TypeSignature Language="C#" Value="public class Tuple<T1,T2,T3,T4,T5> : IComparable, System.Collections.IStructuralComparable, System.Collections.IStructuralEquatable" FrameworkAlternate="dotnet-uwp-10.0;netcore-1.0;netcore-1.1;netframework-4.0;netframework-4.5;netframework-4.5.1;netframework-4.5.2;netframework-4.6;netframework-4.6.1;netframework-4.6.2;netframework-4.7;netframework-4.7.1;netframework-4.7.2;netframework-4.8;netframework-4.8.1;netstandard-1.0;netstandard-1.1;netstandard-1.2;netstandard-1.3;netstandard-1.4;netstandard-1.5;netstandard-1.6;netstandard-2.0" />
<TypeSignature Language="ILAsm" Value=".class public auto ansi beforefieldinit Tuple`5<T1, T2, T3, T4, T5> extends System.Object implements class System.Collections.IStructuralComparable, class System.Collections.IStructuralEquatable, class System.IComparable" FrameworkAlternate="dotnet-uwp-10.0;netcore-1.0;netcore-1.1;netstandard-1.0;netstandard-1.1;netstandard-1.2;netstandard-1.3;netstandard-1.4;netstandard-1.5;netstandard-1.6;netstandard-2.0" />
<TypeSignature Language="DocId" Value="T:System.Tuple`5" />
<TypeSignature Language="VB.NET" Value="Public Class Tuple(Of T1, T2, T3, T4, T5)
Implements IComparable, IStructuralComparable, IStructuralEquatable" FrameworkAlternate="dotnet-uwp-10.0;netcore-1.0;netcore-1.1;netframework-4.0;netframework-4.5;netframework-4.5.1;netframework-4.5.2;netframework-4.6;netframework-4.6.1;netframework-4.6.2;netframework-4.7;netframework-4.7.1;netframework-4.7.2;netframework-4.8;netframework-4.8.1;netstandard-1.0;netstandard-1.1;netstandard-1.2;netstandard-1.3;netstandard-1.4;netstandard-1.5;netstandard-1.6;netstandard-2.0" />
<TypeSignature Language="F#" Value="type Tuple<'T1, 'T2, 'T3, 'T4, 'T5> = class
 interface IStructuralComparable
 interface IStructuralEquatable
 interface IComparable" FrameworkAlternate="dotnet-uwp-10.0;netcore-1.0;netcore-1.1;netstandard-1.0;netstandard-1.1;netstandard-1.2;netstandard-1.3;netstandard-1.4;netstandard-1.5;netstandard-1.6;netstandard-2.0" />
<TypeSignature Language="C++ CLI" Value="generic <typename T1, typename T2, typename T3, typename T4, typename T5>
public ref class Tuple : IComparable, System::Collections::IStructuralComparable, System::Collections::IStructuralEquatable" FrameworkAlternate="dotnet-uwp-10.0;netcore-1.0;netcore-1.1;netframework-4.0;netframework-4.5;netframework-4.5.1;netframework-4.5.2;netframework-4.6;netframework-4.6.1;netframework-4.6.2;netframework-4.7;netframework-4.7.1;netframework-4.7.2;netframework-4.8;netframework-4.8.1;netstandard-1.0;netstandard-1.1;netstandard-1.2;netstandard-1.3;netstandard-1.4;netstandard-1.5;netstandard-1.6;netstandard-2.0" />
<TypeSignature Language="C#" Value="public class Tuple<T1,T2,T3,T4,T5> : IComparable, System.Collections.IStructuralComparable, System.Collections.IStructuralEquatable, System.Runtime.CompilerServices.ITuple" FrameworkAlternate="net-5.0;net-6.0;net-7.0;net-8.0;net-9.0;netcore-2.0;netcore-2.1;netcore-2.2;netcore-3.0;netcore-3.1;netframework-4.7.1-pp;netframework-4.7.2-pp;netframework-4.7-pp;netframework-4.8.1-pp;netframework-4.8-pp;netstandard-2.1" />
<TypeSignature Language="ILAsm" Value=".class public auto ansi beforefieldinit Tuple`5<T1, T2, T3, T4, T5> extends System.Object implements class System.Collections.IStructuralComparable, class System.Collections.IStructuralEquatable, class System.IComparable, class System.Runtime.CompilerServices.ITuple" FrameworkAlternate="net-5.0;net-6.0;net-7.0;net-8.0;net-9.0;netcore-2.0;netcore-2.1;netcore-2.2;netcore-3.0;netcore-3.1;netframework-4.7.1-pp;netframework-4.7.2-pp;netframework-4.7-pp;netframework-4.8.1-pp;netframework-4.8-pp;netstandard-2.1" />
<TypeSignature Language="VB.NET" Value="Public Class Tuple(Of T1, T2, T3, T4, T5)
Implements IComparable, IStructuralComparable, IStructuralEquatable, ITuple" FrameworkAlternate="net-5.0;net-6.0;net-7.0;net-8.0;net-9.0;netcore-2.0;netcore-2.1;netcore-2.2;netcore-3.0;netcore-3.1;netframework-4.7.1-pp;netframework-4.7.2-pp;netframework-4.7-pp;netframework-4.8.1-pp;netframework-4.8-pp;netstandard-2.1" />
<TypeSignature Language="F#" Value="type Tuple<'T1, 'T2, 'T3, 'T4, 'T5> = class
 interface IStructuralComparable
 interface IStructuralEquatable
 interface IComparable
 interface ITuple" FrameworkAlternate="net-5.0;net-6.0;net-7.0;net-8.0;net-9.0;netcore-2.0;netcore-2.1;netcore-2.2;netcore-3.0;netcore-3.1;netframework-4.7.1-pp;netframework-4.7.2-pp;netframework-4.7-pp;netframework-4.8.1-pp;netframework-4.8-pp;netstandard-2.1" />
<TypeSignature Language="C++ CLI" Value="generic <typename T1, typename T2, typename T3, typename T4, typename T5>
public ref class Tuple : IComparable, System::Collections::IStructuralComparable, System::Collections::IStructuralEquatable, System::Runtime::CompilerServices::ITuple" FrameworkAlternate="net-5.0;net-6.0;net-7.0;net-8.0;net-9.0;netcore-2.0;netcore-2.1;netcore-2.2;netcore-3.0;netcore-3.1;netframework-4.7.1-pp;netframework-4.7.2-pp;netframework-4.7-pp;netframework-4.8.1-pp;netframework-4.8-pp;netstandard-2.1" />
<TypeSignature Language="ILAsm" Value=".class public auto ansi serializable beforefieldinit Tuple`5<T1, T2, T3, T4, T5> extends System.Object implements class System.Collections.IStructuralComparable, class System.Collections.IStructuralEquatable, class System.IComparable" FrameworkAlternate="netframework-4.0;netframework-4.5;netframework-4.5.1;netframework-4.5.2;netframework-4.6;netframework-4.6.1;netframework-4.6.2;netframework-4.7" />
<TypeSignature Language="F#" Value="type Tuple<'T1, 'T2, 'T3, 'T4, 'T5> = class
 interface IStructuralEquatable
 interface IStructuralComparable
 interface IComparable" FrameworkAlternate="netframework-4.0;netframework-4.5;netframework-4.5.1;netframework-4.5.2;netframework-4.6;netframework-4.6.1;netframework-4.6.2;netframework-4.7" />
<TypeSignature Language="ILAsm" Value=".class public auto ansi serializable beforefieldinit Tuple`5<T1, T2, T3, T4, T5> extends System.Object implements class System.Collections.IStructuralComparable, class System.Collections.IStructuralEquatable, class System.IComparable, class System.Runtime.CompilerServices.ITuple" FrameworkAlternate="netframework-4.7.1;netframework-4.7.2;netframework-4.8;netframework-4.8.1" />
<TypeSignature Language="F#" Value="type Tuple<'T1, 'T2, 'T3, 'T4, 'T5> = class
 interface IStructuralEquatable
 interface IStructuralComparable
 interface IComparable
 interface ITuple" FrameworkAlternate="netframework-4.7.1;netframework-4.7.2;netframework-4.8;netframework-4.8.1" />
<AssemblyInfo>
<AssemblyName>System.Runtime</AssemblyName>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
<AssemblyVersion>4.0.10.0</AssemblyVersion>
<AssemblyVersion>4.0.20.0</AssemblyVersion>
<AssemblyVersion>4.1.0.0</AssemblyVersion>
<AssemblyVersion>4.2.0.0</AssemblyVersion>
<AssemblyVersion>4.2.1.0</AssemblyVersion>
<AssemblyVersion>4.2.2.0</AssemblyVersion>
<AssemblyVersion>5.0.0.0</AssemblyVersion>
<AssemblyVersion>6.0.0.0</AssemblyVersion>
<AssemblyVersion>7.0.0.0</AssemblyVersion>
<AssemblyVersion>8.0.0.0</AssemblyVersion>
<AssemblyVersion>9.0.0.0</AssemblyVersion>
</AssemblyInfo>
<AssemblyInfo>
<AssemblyName>mscorlib</AssemblyName>
<AssemblyVersion>2.0.5.0</AssemblyVersion>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
</AssemblyInfo>
<AssemblyInfo>
<AssemblyName>netstandard</AssemblyName>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
<AssemblyVersion>2.1.0.0</AssemblyVersion>
</AssemblyInfo>
<TypeForwardingChain>
<TypeForwarding From="mscorlib" FromVersion="4.0.0.0" To="System.Runtime" ToVersion="0.0.0.0" FrameworkAlternate="dotnet-uwp-10.0" />
<TypeForwarding From="netstandard" FromVersion="2.1.0.0" To="System.Runtime" ToVersion="5.0.0.0" FrameworkAlternate="net-5.0" />
<TypeForwarding From="netstandard" FromVersion="2.1.0.0" To="System.Runtime" ToVersion="6.0.0.0" FrameworkAlternate="net-6.0" />
<TypeForwarding From="netstandard" FromVersion="2.1.0.0" To="System.Runtime" ToVersion="7.0.0.0" FrameworkAlternate="net-7.0" />
<TypeForwarding From="netstandard" FromVersion="2.1.0.0" To="System.Runtime" ToVersion="8.0.0.0" FrameworkAlternate="net-8.0" />
<TypeForwarding From="netstandard" FromVersion="2.1.0.0" To="System.Runtime" ToVersion="9.0.0.0" FrameworkAlternate="net-9.0" />
<TypeForwarding From="System.Runtime" FromVersion="4.1.1.1" To="mscorlib" ToVersion="4.0.0.0" FrameworkAlternate="netframework-4.7.1-pp;netframework-4.7.2-pp;netframework-4.7-pp;netframework-4.8.1-pp;netframework-4.8-pp" />
</TypeForwardingChain>
<TypeParameters>
<TypeParameter Name="T1">
<Attributes>
<Attribute FrameworkAlternate="net-8.0;net-9.0">
<AttributeName Language="C#">[System.Runtime.CompilerServices.Nullable(2)]</AttributeName>
<AttributeName Language="F#">[<System.Runtime.CompilerServices.Nullable(2)>]</AttributeName>
</Attribute>
</Attributes>
</TypeParameter>
<TypeParameter Name="T2">
<Attributes>
<Attribute FrameworkAlternate="net-8.0;net-9.0">
<AttributeName Language="C#">[System.Runtime.CompilerServices.Nullable(2)]</AttributeName>
<AttributeName Language="F#">[<System.Runtime.CompilerServices.Nullable(2)>]</AttributeName>
</Attribute>
</Attributes>
</TypeParameter>
<TypeParameter Name="T3">
<Attributes>
<Attribute FrameworkAlternate="net-8.0;net-9.0">
<AttributeName Language="C#">[System.Runtime.CompilerServices.Nullable(2)]</AttributeName>
<AttributeName Language="F#">[<System.Runtime.CompilerServices.Nullable(2)>]</AttributeName>
</Attribute>
</Attributes>
</TypeParameter>
<TypeParameter Name="T4">
<Attributes>
<Attribute FrameworkAlternate="net-8.0;net-9.0">
<AttributeName Language="C#">[System.Runtime.CompilerServices.Nullable(2)]</AttributeName>
<AttributeName Language="F#">[<System.Runtime.CompilerServices.Nullable(2)>]</AttributeName>
</Attribute>
</Attributes>
</TypeParameter>
<TypeParameter Name="T5">
<Attributes>
<Attribute FrameworkAlternate="net-8.0;net-9.0">
<AttributeName Language="C#">[System.Runtime.CompilerServices.Nullable(2)]</AttributeName>
<AttributeName Language="F#">[<System.Runtime.CompilerServices.Nullable(2)>]</AttributeName>
</Attribute>
</Attributes>
</TypeParameter>
</TypeParameters>
<Base>
<BaseTypeName>System.Object</BaseTypeName>
</Base>
<Interfaces>
<Interface>
<InterfaceName>System.Collections.IStructuralComparable</InterfaceName>
</Interface>
<Interface>
<InterfaceName>System.Collections.IStructuralEquatable</InterfaceName>
</Interface>
<Interface>
<InterfaceName>System.IComparable</InterfaceName>
</Interface>
<Interface FrameworkAlternate="net-5.0;net-6.0;net-7.0;net-8.0;net-9.0;netcore-2.0;netcore-2.1;netcore-2.2;netcore-3.0;netcore-3.1;netframework-4.7.1;netframework-4.7.1-pp;netframework-4.7.2;netframework-4.7.2-pp;netframework-4.7-pp;netframework-4.8;netframework-4.8.1;netframework-4.8.1-pp;netframework-4.8-pp;netstandard-2.1">
<InterfaceName>System.Runtime.CompilerServices.ITuple</InterfaceName>
</Interface>
</Interfaces>
<Attributes>
<Attribute FrameworkAlternate="net-8.0;net-9.0">
<AttributeName Language="C#">[System.Runtime.CompilerServices.Nullable(0)]</AttributeName>
<AttributeName Language="F#">[<System.Runtime.CompilerServices.Nullable(0)>]</AttributeName>
</Attribute>
<Attribute FrameworkAlternate="netframework-4.0;netframework-4.5;netframework-4.5.1;netframework-4.5.2;netframework-4.6;netframework-4.6.1;netframework-4.6.2;netframework-4.7;netframework-4.7.1;netframework-4.7.2;netframework-4.8;netframework-4.8.1">
<AttributeName Language="C#">[System.Serializable]</AttributeName>
<AttributeName Language="F#">[<System.Serializable>]</AttributeName>
</Attribute>
</Attributes>
<Docs>
<typeparam name="T1">The type of the tuple's first component.</typeparam>
<typeparam name="T2">The type of the tuple's second component.</typeparam>
<typeparam name="T3">The type of the tuple's third component.</typeparam>
<typeparam name="T4">The type of the tuple's fourth component.</typeparam>
<typeparam name="T5">The type of the tuple's fifth component.</typeparam>
<summary>Represents a 5-tuple, or quintuple.</summary>
<remarks>
<format type="text/markdown"><![CDATA[
## Remarks
A tuple is a data structure that has a specific number and sequence of values. The <xref:System.Tuple%605> class represents a 5-tuple, or quintuple, which is a tuple that has five components.
You can instantiate a <xref:System.Tuple%605> object by calling either the <xref:System.Tuple%605.%23ctor%2A> constructor or the static <xref:System.Tuple.Create%60%605%28%60%600%2C%60%601%2C%60%602%2C%60%603%2C%60%604%29?displayProperty=nameWithType> method. You can retrieve the value of the tuple's components by using the read-only <xref:System.Tuple%605.Item1%2A>, <xref:System.Tuple%605.Item2%2A>, <xref:System.Tuple%605.Item3%2A>, <xref:System.Tuple%605.Item4%2A>, and <xref:System.Tuple%605.Item5%2A> instance properties.
Tuples are commonly used in four different ways:
- To represent a single set of data. For example, a tuple can represent a database record, and its components can represent individual fields of the record.
- To provide easy access to, and manipulation of, a data set. The following example defines an array of <xref:System.Tuple%605> objects that contain the names of running backs in American football, the number of games in which they played, and the number of carries, total yards gained, and touchdowns scored during those games. The array is passed to the `ComputeStatistics` method, which calculates each running back's number of carries per game, average yards per game, average yards per carry, and average number of touchdowns per attempt.
:::code language="csharp" source="~/snippets/csharp/System/TupleT1,T2,T3,T4,T5/Overview/example1.cs" id="Snippet1":::
:::code language="fsharp" source="~/snippets/fsharp/System/TupleT1,T2,T3,T4,T5/Overview/example1.fs" id="Snippet1":::
:::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.tuple`5.class/vb/example1.vb" id="Snippet1":::
- To return multiple values from a method without the use of `out` parameters (in C#) or `ByRef` parameters (in Visual Basic). For example, the previous example returns its computed statistics, along with the name of the player, in an array of <xref:System.Tuple%605> objects.
- To pass multiple values to a method through a single parameter. For example, the <xref:System.Threading.Thread.Start%28System.Object%29?displayProperty=nameWithType> method has a single parameter that lets you supply one value to the method that the thread executes at startup. If you supply a <xref:System.Tuple%605> object as the method argument, you can supply the thread's startup routine with five items of data.
]]></format>
</remarks>
<altmember cref="T:System.Tuple" />
<altmember cref="T:System.Tuple`1" />
<altmember cref="T:System.Tuple`2" />
<altmember cref="T:System.Tuple`3" />
<altmember cref="T:System.Tuple`4" />
<altmember cref="T:System.Tuple`6" />
<altmember cref="T:System.Tuple`7" />
<altmember cref="T:System.Tuple`8" />
</Docs>
<Members>
<Member MemberName=".ctor">
<MemberSignature Language="C#" Value="public Tuple (T1 item1, T2 item2, T3 item3, T4 item4, T5 item5);" />
<MemberSignature Language="ILAsm" Value=".method public hidebysig specialname rtspecialname instance void .ctor(!T1 item1, !T2 item2, !T3 item3, !T4 item4, !T5 item5) cil managed" />
<MemberSignature Language="DocId" Value="M:System.Tuple`5.#ctor(`0,`1,`2,`3,`4)" />
<MemberSignature Language="VB.NET" Value="Public Sub New (item1 As T1, item2 As T2, item3 As T3, item4 As T4, item5 As T5)" />
<MemberSignature Language="F#" Value="new Tuple<'T1, 'T2, 'T3, 'T4, 'T5> : 'T1 * 'T2 * 'T3 * 'T4 * 'T5 -> Tuple<'T1, 'T2, 'T3, 'T4, 'T5>" Usage="new System.Tuple<'T1, 'T2, 'T3, 'T4, 'T5> (item1, item2, item3, item4, item5)" />
<MemberSignature Language="C++ CLI" Value="public:
 Tuple(T1 item1, T2 item2, T3 item3, T4 item4, T5 item5);" />
<MemberType>Constructor</MemberType>
<AssemblyInfo>
<AssemblyName>System.Runtime</AssemblyName>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
<AssemblyVersion>4.0.10.0</AssemblyVersion>
<AssemblyVersion>4.0.20.0</AssemblyVersion>
<AssemblyVersion>4.1.0.0</AssemblyVersion>
<AssemblyVersion>4.2.0.0</AssemblyVersion>
<AssemblyVersion>4.2.1.0</AssemblyVersion>
<AssemblyVersion>4.2.2.0</AssemblyVersion>
<AssemblyVersion>5.0.0.0</AssemblyVersion>
<AssemblyVersion>6.0.0.0</AssemblyVersion>
<AssemblyVersion>7.0.0.0</AssemblyVersion>
<AssemblyVersion>8.0.0.0</AssemblyVersion>
<AssemblyVersion>9.0.0.0</AssemblyVersion>
</AssemblyInfo>
<AssemblyInfo>
<AssemblyName>mscorlib</AssemblyName>
<AssemblyVersion>2.0.5.0</AssemblyVersion>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
</AssemblyInfo>
<AssemblyInfo>
<AssemblyName>netstandard</AssemblyName>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
<AssemblyVersion>2.1.0.0</AssemblyVersion>
</AssemblyInfo>
<Parameters>
<Parameter Name="item1" Type="T1" />
<Parameter Name="item2" Type="T2" />
<Parameter Name="item3" Type="T3" />
<Parameter Name="item4" Type="T4" />
<Parameter Name="item5" Type="T5" />
</Parameters>
<Docs>
<param name="item1">The value of the tuple's first component.</param>
<param name="item2">The value of the tuple's second component.</param>
<param name="item3">The value of the tuple's third component.</param>
<param name="item4">The value of the tuple's fourth component.</param>
<param name="item5">The value of the tuple's fifth component.</param>
<summary>Initializes a new instance of the <see cref="T:System.Tuple`5" /> class.</summary>
<remarks>
<format type="text/markdown"><![CDATA[
## Remarks
You can also use the static <xref:System.Tuple.Create%60%605%28%60%600%2C%60%601%2C%60%602%2C%60%603%2C%60%604%29?displayProperty=nameWithType> method to instantiate a 5-tuple object without having to explicitly specify the types of its components. The following example uses the <xref:System.Tuple.Create%60%605%28%60%600%2C%60%601%2C%60%602%2C%60%603%2C%60%604%29?displayProperty=nameWithType> method to instantiate a 5-tuple whose first component is of type <xref:System.String> and its remaining four components are of type <xref:System.Int32>.
:::code language="csharp" source="~/snippets/csharp/System/Tuple/Overview/create1.cs" id="Snippet9":::
:::code language="fsharp" source="~/snippets/fsharp/System/Tuple/Overview/create1.fs" id="Snippet9":::
:::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.tuple.create/vb/create1.vb" id="Snippet9":::
This is equivalent to the following call to the <xref:System.Tuple%605.%23ctor%2A> class constructor.
:::code language="csharp" source="~/snippets/csharp/System/Tuple/Overview/create1.cs" id="Snippet10":::
:::code language="fsharp" source="~/snippets/fsharp/System/Tuple/Overview/create1.fs" id="Snippet10":::
:::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.tuple.create/vb/create1.vb" id="Snippet10":::
]]></format>
</remarks>
</Docs>
</Member>
<Member MemberName="Equals">
<MemberSignature Language="C#" Value="public override bool Equals (object obj);" FrameworkAlternate="dotnet-uwp-10.0;netcore-1.0;netcore-1.1;netcore-2.0;netcore-2.1;netcore-2.2;netframework-4.0;netframework-4.5;netframework-4.5.1;netframework-4.5.2;netframework-4.6;netframework-4.6.1;netframework-4.6.2;netframework-4.7;netframework-4.7.1;netframework-4.7.2;netframework-4.8;netframework-4.8.1;netstandard-1.0;netstandard-1.1;netstandard-1.2;netstandard-1.3;netstandard-1.4;netstandard-1.5;netstandard-1.6;netstandard-2.0;netstandard-2.1" />
<MemberSignature Language="ILAsm" Value=".method public hidebysig virtual instance bool Equals(object obj) cil managed" />
<MemberSignature Language="DocId" Value="M:System.Tuple`5.Equals(System.Object)" />
<MemberSignature Language="VB.NET" Value="Public Overrides Function Equals (obj As Object) As Boolean" />
<MemberSignature Language="F#" Value="override this.Equals : obj -> bool" Usage="tuple.Equals obj" />
<MemberSignature Language="C++ CLI" Value="public:
 override bool Equals(System::Object ^ obj);" />
<MemberSignature Language="C#" Value="public override bool Equals (object? obj);" FrameworkAlternate="net-5.0;net-6.0;net-7.0;net-8.0;net-9.0;netcore-3.0;netcore-3.1;netframework-4.7.1-pp;netframework-4.7.2-pp;netframework-4.7-pp;netframework-4.8.1-pp;netframework-4.8-pp" />
<MemberType>Method</MemberType>
<AssemblyInfo>
<AssemblyName>System.Runtime</AssemblyName>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
<AssemblyVersion>4.0.10.0</AssemblyVersion>
<AssemblyVersion>4.0.20.0</AssemblyVersion>
<AssemblyVersion>4.1.0.0</AssemblyVersion>
<AssemblyVersion>4.2.0.0</AssemblyVersion>
<AssemblyVersion>4.2.1.0</AssemblyVersion>
<AssemblyVersion>4.2.2.0</AssemblyVersion>
<AssemblyVersion>5.0.0.0</AssemblyVersion>
<AssemblyVersion>6.0.0.0</AssemblyVersion>
<AssemblyVersion>7.0.0.0</AssemblyVersion>
<AssemblyVersion>8.0.0.0</AssemblyVersion>
<AssemblyVersion>9.0.0.0</AssemblyVersion>
</AssemblyInfo>
<AssemblyInfo>
<AssemblyName>mscorlib</AssemblyName>
<AssemblyVersion>2.0.5.0</AssemblyVersion>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
</AssemblyInfo>
<AssemblyInfo>
<AssemblyName>netstandard</AssemblyName>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
<AssemblyVersion>2.1.0.0</AssemblyVersion>
</AssemblyInfo>
<ReturnValue>
<ReturnType>System.Boolean</ReturnType>
</ReturnValue>
<Parameters>
<Parameter Name="obj" Type="System.Object">
<Attributes>
<Attribute FrameworkAlternate="net-6.0;net-7.0;net-8.0;net-9.0">
<AttributeName Language="C#">[System.Diagnostics.CodeAnalysis.NotNullWhen(true)]</AttributeName>
<AttributeName Language="F#">[<System.Diagnostics.CodeAnalysis.NotNullWhen(true)>]</AttributeName>
</Attribute>
</Attributes>
</Parameter>
</Parameters>
<Docs>
<param name="obj">The object to compare with this instance.</param>
<summary>Returns a value that indicates whether the current <see cref="T:System.Tuple`5" /> object is equal to a specified object.</summary>
<returns>
<see langword="true" /> if the current instance is equal to the specified object; otherwise, <see langword="false" />.</returns>
<remarks>
<format type="text/markdown"><![CDATA[
## Remarks
The `obj` parameter is considered to be equal to the current instance under the following conditions:
- It is a <xref:System.Tuple%605> object.
- Its five components are of the same types as the current instance.
- Its five components are equal to those of the current instance. Equality is determined by the default object equality comparer for each component.
## Examples
The following example defines an array of 5-tuple objects that contain data about the temperatures of patients in two test groups. The first component of the array provides the number of the test group, and the second through fifth components provide the temperatures of a patient at hourly intervals. The <xref:System.Tuple%605.Equals%28System.Object%29?displayProperty=nameWithType> method is called to compare every <xref:System.Tuple%605> object with every other <xref:System.Tuple%605> object. The output illustrates that the <xref:System.Tuple%605.Equals%2A> method returns `true` only when all five components of the <xref:System.Tuple%605> objects have equal values.
:::code language="csharp" source="~/snippets/csharp/System/TupleT1,T2,T3,T4,T5/Equals/equals1.cs" id="Snippet1":::
:::code language="fsharp" source="~/snippets/fsharp/System/TupleT1,T2,T3,T4,T5/Equals/equals1.fs" id="Snippet1":::
:::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.tuple`5.equals/vb/equals1.vb" id="Snippet1":::
]]></format>
</remarks>
</Docs>
</Member>
<Member MemberName="GetHashCode">
<MemberSignature Language="C#" Value="public override int GetHashCode ();" />
<MemberSignature Language="ILAsm" Value=".method public hidebysig virtual instance int32 GetHashCode() cil managed" />
<MemberSignature Language="DocId" Value="M:System.Tuple`5.GetHashCode" />
<MemberSignature Language="VB.NET" Value="Public Overrides Function GetHashCode () As Integer" />
<MemberSignature Language="F#" Value="override this.GetHashCode : unit -> int" Usage="tuple.GetHashCode " />
<MemberSignature Language="C++ CLI" Value="public:
 override int GetHashCode();" />
<MemberType>Method</MemberType>
<AssemblyInfo>
<AssemblyName>System.Runtime</AssemblyName>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
<AssemblyVersion>4.0.10.0</AssemblyVersion>
<AssemblyVersion>4.0.20.0</AssemblyVersion>
<AssemblyVersion>4.1.0.0</AssemblyVersion>
<AssemblyVersion>4.2.0.0</AssemblyVersion>
<AssemblyVersion>4.2.1.0</AssemblyVersion>
<AssemblyVersion>4.2.2.0</AssemblyVersion>
<AssemblyVersion>5.0.0.0</AssemblyVersion>
<AssemblyVersion>6.0.0.0</AssemblyVersion>
<AssemblyVersion>7.0.0.0</AssemblyVersion>
<AssemblyVersion>8.0.0.0</AssemblyVersion>
<AssemblyVersion>9.0.0.0</AssemblyVersion>
</AssemblyInfo>
<AssemblyInfo>
<AssemblyName>mscorlib</AssemblyName>
<AssemblyVersion>2.0.5.0</AssemblyVersion>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
</AssemblyInfo>
<AssemblyInfo>
<AssemblyName>netstandard</AssemblyName>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
<AssemblyVersion>2.1.0.0</AssemblyVersion>
</AssemblyInfo>
<ReturnValue>
<ReturnType>System.Int32</ReturnType>
</ReturnValue>
<Parameters />
<Docs>
<summary>Returns the hash code for the current <see cref="T:System.Tuple`5" /> object.</summary>
<returns>A 32-bit signed integer hash code.</returns>
<remarks>To be added.</remarks>
</Docs>
</Member>
<Member MemberName="Item1">
<MemberSignature Language="C#" Value="public T1 Item1 { get; }" />
<MemberSignature Language="ILAsm" Value=".property instance !T1 Item1" />
<MemberSignature Language="DocId" Value="P:System.Tuple`5.Item1" />
<MemberSignature Language="VB.NET" Value="Public ReadOnly Property Item1 As T1" />
<MemberSignature Language="F#" Value="member this.Item1 : 'T1" Usage="System.Tuple<'T1, 'T2, 'T3, 'T4, 'T5>.Item1" />
<MemberSignature Language="C++ CLI" Value="public:
 property T1 Item1 { T1 get(); };" />
<MemberType>Property</MemberType>
<AssemblyInfo>
<AssemblyName>System.Runtime</AssemblyName>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
<AssemblyVersion>4.0.10.0</AssemblyVersion>
<AssemblyVersion>4.0.20.0</AssemblyVersion>
<AssemblyVersion>4.1.0.0</AssemblyVersion>
<AssemblyVersion>4.2.0.0</AssemblyVersion>
<AssemblyVersion>4.2.1.0</AssemblyVersion>
<AssemblyVersion>4.2.2.0</AssemblyVersion>
<AssemblyVersion>5.0.0.0</AssemblyVersion>
<AssemblyVersion>6.0.0.0</AssemblyVersion>
<AssemblyVersion>7.0.0.0</AssemblyVersion>
<AssemblyVersion>8.0.0.0</AssemblyVersion>
<AssemblyVersion>9.0.0.0</AssemblyVersion>
</AssemblyInfo>
<AssemblyInfo>
<AssemblyName>mscorlib</AssemblyName>
<AssemblyVersion>2.0.5.0</AssemblyVersion>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
</AssemblyInfo>
<AssemblyInfo>
<AssemblyName>netstandard</AssemblyName>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
<AssemblyVersion>2.1.0.0</AssemblyVersion>
</AssemblyInfo>
<ReturnValue>
<ReturnType>T1</ReturnType>
</ReturnValue>
<Docs>
<summary>Gets the value of the current <see cref="T:System.Tuple`5" /> object's first component.</summary>
<value>The value of the current <see cref="T:System.Tuple`5" /> object's first component.</value>
<remarks>
<format type="text/markdown"><![CDATA[
## Remarks
You can dynamically determine the type of the <xref:System.Tuple%605.Item1%2A> component in one of two ways:
- By calling the `GetType` method on the value that is returned by the <xref:System.Tuple%605.Item1%2A> property.
- By retrieving the <xref:System.Type> object that represents the <xref:System.Tuple%605> object, and retrieving the first element from the array that is returned by its <xref:System.Type.GetGenericArguments%2A?displayProperty=nameWithType> method.
## Examples
The following example defines an array of <xref:System.Tuple%605> objects whose components contain the name of a state in the United States, its population in 1990 and 2000, its population change in this 10-year period, and the percentage change in its population. It then iterates through the array and displays the value of each component in a tuple.
:::code language="csharp" source="~/snippets/csharp/System/TupleT1,T2,T3,T4,T5/Item1/item1.cs" id="Snippet1":::
:::code language="fsharp" source="~/snippets/fsharp/System/TupleT1,T2,T3,T4,T5/Item1/item1.fs" id="Snippet1":::
:::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.tuple`5.item1/vb/item1.vb" id="Snippet1":::
]]></format>
</remarks>
</Docs>
</Member>
<Member MemberName="Item2">
<MemberSignature Language="C#" Value="public T2 Item2 { get; }" />
<MemberSignature Language="ILAsm" Value=".property instance !T2 Item2" />
<MemberSignature Language="DocId" Value="P:System.Tuple`5.Item2" />
<MemberSignature Language="VB.NET" Value="Public ReadOnly Property Item2 As T2" />
<MemberSignature Language="F#" Value="member this.Item2 : 'T2" Usage="System.Tuple<'T1, 'T2, 'T3, 'T4, 'T5>.Item2" />
<MemberSignature Language="C++ CLI" Value="public:
 property T2 Item2 { T2 get(); };" />
<MemberType>Property</MemberType>
<AssemblyInfo>
<AssemblyName>System.Runtime</AssemblyName>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
<AssemblyVersion>4.0.10.0</AssemblyVersion>
<AssemblyVersion>4.0.20.0</AssemblyVersion>
<AssemblyVersion>4.1.0.0</AssemblyVersion>
<AssemblyVersion>4.2.0.0</AssemblyVersion>
<AssemblyVersion>4.2.1.0</AssemblyVersion>
<AssemblyVersion>4.2.2.0</AssemblyVersion>
<AssemblyVersion>5.0.0.0</AssemblyVersion>
<AssemblyVersion>6.0.0.0</AssemblyVersion>
<AssemblyVersion>7.0.0.0</AssemblyVersion>
<AssemblyVersion>8.0.0.0</AssemblyVersion>
<AssemblyVersion>9.0.0.0</AssemblyVersion>
</AssemblyInfo>
<AssemblyInfo>
<AssemblyName>mscorlib</AssemblyName>
<AssemblyVersion>2.0.5.0</AssemblyVersion>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
</AssemblyInfo>
<AssemblyInfo>
<AssemblyName>netstandard</AssemblyName>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
<AssemblyVersion>2.1.0.0</AssemblyVersion>
</AssemblyInfo>
<ReturnValue>
<ReturnType>T2</ReturnType>
</ReturnValue>
<Docs>
<summary>Gets the value of the current <see cref="T:System.Tuple`5" /> object's second component.</summary>
<value>The value of the current <see cref="T:System.Tuple`5" /> object's second component.</value>
<remarks>
<format type="text/markdown"><![CDATA[
## Remarks
You can dynamically determine the type of the <xref:System.Tuple%604.Item2%2A> component in one of two ways:
- By calling the `GetType` method on the value that is returned by the <xref:System.Tuple%604.Item2%2A> property.
- By retrieving the <xref:System.Type> object that represents the <xref:System.Tuple%604> object, and retrieving the second element from the array that is returned by its <xref:System.Type.GetGenericArguments%2A?displayProperty=nameWithType> method.
## Examples
The following example defines an array of <xref:System.Tuple%605> objects whose components contain the name of a state in the United States, its population in 1990 and 2000, its population change in this 10-year period, and the percentage change in its population. It then iterates through the array and displays the value of each component in a tuple.
:::code language="csharp" source="~/snippets/csharp/System/TupleT1,T2,T3,T4,T5/Item1/item1.cs" id="Snippet1":::
:::code language="fsharp" source="~/snippets/fsharp/System/TupleT1,T2,T3,T4,T5/Item1/item1.fs" id="Snippet1":::
:::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.tuple`5.item1/vb/item1.vb" id="Snippet1":::
]]></format>
</remarks>
</Docs>
</Member>
<Member MemberName="Item3">
<MemberSignature Language="C#" Value="public T3 Item3 { get; }" />
<MemberSignature Language="ILAsm" Value=".property instance !T3 Item3" />
<MemberSignature Language="DocId" Value="P:System.Tuple`5.Item3" />
<MemberSignature Language="VB.NET" Value="Public ReadOnly Property Item3 As T3" />
<MemberSignature Language="F#" Value="member this.Item3 : 'T3" Usage="System.Tuple<'T1, 'T2, 'T3, 'T4, 'T5>.Item3" />
<MemberSignature Language="C++ CLI" Value="public:
 property T3 Item3 { T3 get(); };" />
<MemberType>Property</MemberType>
<AssemblyInfo>
<AssemblyName>System.Runtime</AssemblyName>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
<AssemblyVersion>4.0.10.0</AssemblyVersion>
<AssemblyVersion>4.0.20.0</AssemblyVersion>
<AssemblyVersion>4.1.0.0</AssemblyVersion>
<AssemblyVersion>4.2.0.0</AssemblyVersion>
<AssemblyVersion>4.2.1.0</AssemblyVersion>
<AssemblyVersion>4.2.2.0</AssemblyVersion>
<AssemblyVersion>5.0.0.0</AssemblyVersion>
<AssemblyVersion>6.0.0.0</AssemblyVersion>
<AssemblyVersion>7.0.0.0</AssemblyVersion>
<AssemblyVersion>8.0.0.0</AssemblyVersion>
<AssemblyVersion>9.0.0.0</AssemblyVersion>
</AssemblyInfo>
<AssemblyInfo>
<AssemblyName>mscorlib</AssemblyName>
<AssemblyVersion>2.0.5.0</AssemblyVersion>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
</AssemblyInfo>
<AssemblyInfo>
<AssemblyName>netstandard</AssemblyName>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
<AssemblyVersion>2.1.0.0</AssemblyVersion>
</AssemblyInfo>
<ReturnValue>
<ReturnType>T3</ReturnType>
</ReturnValue>
<Docs>
<summary>Gets the value of the current <see cref="T:System.Tuple`5" /> object's third component.</summary>
<value>The value of the current <see cref="T:System.Tuple`5" /> object's third component.</value>
<remarks>
<format type="text/markdown"><![CDATA[
## Remarks
You can dynamically determine the type of the <xref:System.Tuple%604.Item2%2A> component in one of two ways:
- By calling the `GetType` method on the value that is returned by the <xref:System.Tuple%604.Item2%2A> property.
- By retrieving the <xref:System.Type> object that represents the <xref:System.Tuple%604> object, and retrieving the second element from the array that is returned by its <xref:System.Type.GetGenericArguments%2A?displayProperty=nameWithType> method.
## Examples
The following example defines an array of <xref:System.Tuple%605> objects whose components contain the name of a state in the United States, its population in 1990 and 2000, its population change in this 10-year period, and the percentage change in its population. It then iterates through the array and displays the value of each component in a tuple.
:::code language="csharp" source="~/snippets/csharp/System/TupleT1,T2,T3,T4,T5/Item1/item1.cs" id="Snippet1":::
:::code language="fsharp" source="~/snippets/fsharp/System/TupleT1,T2,T3,T4,T5/Item1/item1.fs" id="Snippet1":::
:::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.tuple`5.item1/vb/item1.vb" id="Snippet1":::
]]></format>
</remarks>
</Docs>
</Member>
<Member MemberName="Item4">
<MemberSignature Language="C#" Value="public T4 Item4 { get; }" />
<MemberSignature Language="ILAsm" Value=".property instance !T4 Item4" />
<MemberSignature Language="DocId" Value="P:System.Tuple`5.Item4" />
<MemberSignature Language="VB.NET" Value="Public ReadOnly Property Item4 As T4" />
<MemberSignature Language="F#" Value="member this.Item4 : 'T4" Usage="System.Tuple<'T1, 'T2, 'T3, 'T4, 'T5>.Item4" />
<MemberSignature Language="C++ CLI" Value="public:
 property T4 Item4 { T4 get(); };" />
<MemberType>Property</MemberType>
<AssemblyInfo>
<AssemblyName>System.Runtime</AssemblyName>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
<AssemblyVersion>4.0.10.0</AssemblyVersion>
<AssemblyVersion>4.0.20.0</AssemblyVersion>
<AssemblyVersion>4.1.0.0</AssemblyVersion>
<AssemblyVersion>4.2.0.0</AssemblyVersion>
<AssemblyVersion>4.2.1.0</AssemblyVersion>
<AssemblyVersion>4.2.2.0</AssemblyVersion>
<AssemblyVersion>5.0.0.0</AssemblyVersion>
<AssemblyVersion>6.0.0.0</AssemblyVersion>
<AssemblyVersion>7.0.0.0</AssemblyVersion>
<AssemblyVersion>8.0.0.0</AssemblyVersion>
<AssemblyVersion>9.0.0.0</AssemblyVersion>
</AssemblyInfo>
<AssemblyInfo>
<AssemblyName>mscorlib</AssemblyName>
<AssemblyVersion>2.0.5.0</AssemblyVersion>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
</AssemblyInfo>
<AssemblyInfo>
<AssemblyName>netstandard</AssemblyName>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
<AssemblyVersion>2.1.0.0</AssemblyVersion>
</AssemblyInfo>
<ReturnValue>
<ReturnType>T4</ReturnType>
</ReturnValue>
<Docs>
<summary>Gets the value of the current <see cref="T:System.Tuple`5" /> object's fourth component.</summary>
<value>The value of the current <see cref="T:System.Tuple`5" /> object's fourth component.</value>
<remarks>
<format type="text/markdown"><![CDATA[
## Remarks
You can dynamically determine the type of the <xref:System.Tuple%604.Item2%2A> component in one of two ways:
- By calling the `GetType` method on the value that is returned by the <xref:System.Tuple%604.Item2%2A> property.
- By retrieving the <xref:System.Type> object that represents the <xref:System.Tuple%604> object, and retrieving the second element from the array that is returned by its <xref:System.Type.GetGenericArguments%2A?displayProperty=nameWithType> method.
## Examples
The following example defines an array of <xref:System.Tuple%605> objects whose components contain the name of a state in the United States, its population in 1990 and 2000, its population change in this 10-year period, and the percentage change in its population. It then iterates through the array and displays the value of each component in a tuple.
:::code language="csharp" source="~/snippets/csharp/System/TupleT1,T2,T3,T4,T5/Item1/item1.cs" id="Snippet1":::
:::code language="fsharp" source="~/snippets/fsharp/System/TupleT1,T2,T3,T4,T5/Item1/item1.fs" id="Snippet1":::
:::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.tuple`5.item1/vb/item1.vb" id="Snippet1":::
]]></format>
</remarks>
</Docs>
</Member>
<Member MemberName="Item5">
<MemberSignature Language="C#" Value="public T5 Item5 { get; }" />
<MemberSignature Language="ILAsm" Value=".property instance !T5 Item5" />
<MemberSignature Language="DocId" Value="P:System.Tuple`5.Item5" />
<MemberSignature Language="VB.NET" Value="Public ReadOnly Property Item5 As T5" />
<MemberSignature Language="F#" Value="member this.Item5 : 'T5" Usage="System.Tuple<'T1, 'T2, 'T3, 'T4, 'T5>.Item5" />
<MemberSignature Language="C++ CLI" Value="public:
 property T5 Item5 { T5 get(); };" />
<MemberType>Property</MemberType>
<AssemblyInfo>
<AssemblyName>System.Runtime</AssemblyName>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
<AssemblyVersion>4.0.10.0</AssemblyVersion>
<AssemblyVersion>4.0.20.0</AssemblyVersion>
<AssemblyVersion>4.1.0.0</AssemblyVersion>
<AssemblyVersion>4.2.0.0</AssemblyVersion>
<AssemblyVersion>4.2.1.0</AssemblyVersion>
<AssemblyVersion>4.2.2.0</AssemblyVersion>
<AssemblyVersion>5.0.0.0</AssemblyVersion>
<AssemblyVersion>6.0.0.0</AssemblyVersion>
<AssemblyVersion>7.0.0.0</AssemblyVersion>
<AssemblyVersion>8.0.0.0</AssemblyVersion>
<AssemblyVersion>9.0.0.0</AssemblyVersion>
</AssemblyInfo>
<AssemblyInfo>
<AssemblyName>mscorlib</AssemblyName>
<AssemblyVersion>2.0.5.0</AssemblyVersion>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
</AssemblyInfo>
<AssemblyInfo>
<AssemblyName>netstandard</AssemblyName>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
<AssemblyVersion>2.1.0.0</AssemblyVersion>
</AssemblyInfo>
<ReturnValue>
<ReturnType>T5</ReturnType>
</ReturnValue>
<Docs>
<summary>Gets the value of the current <see cref="T:System.Tuple`5" /> object's fifth component.</summary>
<value>The value of the current <see cref="T:System.Tuple`5" /> object's fifth component.</value>
<remarks>
<format type="text/markdown"><![CDATA[
## Remarks
You can dynamically determine the type of the <xref:System.Tuple%604.Item2%2A> component in one of two ways:
- By calling the `GetType` method on the value that is returned by the <xref:System.Tuple%604.Item2%2A> property.
- By retrieving the <xref:System.Type> object that represents the <xref:System.Tuple%604> object, and retrieving the second element from the array that is returned by its <xref:System.Type.GetGenericArguments%2A?displayProperty=nameWithType> method.
## Examples
The following example defines an array of <xref:System.Tuple%605> objects whose components contain the name of a state in the United Dates, its population in 1990 and 2000, its population change in this 10-year period, and the percentage change in its population. It then iterates through the array and displays the value of each component in a tuple.
:::code language="csharp" source="~/snippets/csharp/System/TupleT1,T2,T3,T4,T5/Item1/item1.cs" id="Snippet1":::
:::code language="fsharp" source="~/snippets/fsharp/System/TupleT1,T2,T3,T4,T5/Item1/item1.fs" id="Snippet1":::
:::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.tuple`5.item1/vb/item1.vb" id="Snippet1":::
]]></format>
</remarks>
</Docs>
</Member>
<Member MemberName="System.Collections.IStructuralComparable.CompareTo">
<MemberSignature Language="C#" Value="int IStructuralComparable.CompareTo (object other, System.Collections.IComparer comparer);" />
<MemberSignature Language="ILAsm" Value=".method hidebysig newslot virtual instance int32 System.Collections.IStructuralComparable.CompareTo(object other, class System.Collections.IComparer comparer) cil managed" />
<MemberSignature Language="DocId" Value="M:System.Tuple`5.System#Collections#IStructuralComparable#CompareTo(System.Object,System.Collections.IComparer)" />
<MemberSignature Language="VB.NET" Value="Function CompareTo (other As Object, comparer As IComparer) As Integer Implements IStructuralComparable.CompareTo" />
<MemberSignature Language="F#" Value="abstract member System.Collections.IStructuralComparable.CompareTo : obj * System.Collections.IComparer -> int
override this.System.Collections.IStructuralComparable.CompareTo : obj * System.Collections.IComparer -> int" Usage="tuple.System.Collections.IStructuralComparable.CompareTo (other, comparer)" />
<MemberSignature Language="C++ CLI" Value=" virtual int System.Collections.IStructuralComparable.CompareTo(System::Object ^ other, System::Collections::IComparer ^ comparer) = System::Collections::IStructuralComparable::CompareTo;" />
<MemberType>Method</MemberType>
<Implements>
<InterfaceMember>M:System.Collections.IStructuralComparable.CompareTo(System.Object,System.Collections.IComparer)</InterfaceMember>
</Implements>
<AssemblyInfo>
<AssemblyName>System.Runtime</AssemblyName>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
<AssemblyVersion>4.0.10.0</AssemblyVersion>
<AssemblyVersion>4.0.20.0</AssemblyVersion>
<AssemblyVersion>4.1.0.0</AssemblyVersion>
<AssemblyVersion>4.2.0.0</AssemblyVersion>
<AssemblyVersion>4.2.1.0</AssemblyVersion>
<AssemblyVersion>4.2.2.0</AssemblyVersion>
<AssemblyVersion>5.0.0.0</AssemblyVersion>
<AssemblyVersion>6.0.0.0</AssemblyVersion>
<AssemblyVersion>7.0.0.0</AssemblyVersion>
<AssemblyVersion>8.0.0.0</AssemblyVersion>
<AssemblyVersion>9.0.0.0</AssemblyVersion>
</AssemblyInfo>
<AssemblyInfo>
<AssemblyName>mscorlib</AssemblyName>
<AssemblyVersion>2.0.5.0</AssemblyVersion>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
</AssemblyInfo>
<AssemblyInfo>
<AssemblyName>netstandard</AssemblyName>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
<AssemblyVersion>2.1.0.0</AssemblyVersion>
</AssemblyInfo>
<ReturnValue>
<ReturnType>System.Int32</ReturnType>
</ReturnValue>
<Parameters>
<Parameter Name="other" Type="System.Object" />
<Parameter Name="comparer" Type="System.Collections.IComparer" />
</Parameters>
<Docs>
<param name="other">An object to compare with the current instance.</param>
<param name="comparer">An object that provides custom rules for comparison.</param>
<summary>Compares the current <see cref="T:System.Tuple`5" /> object to a specified object by using a specified comparer and returns an integer that indicates whether the current object is before, after, or in the same position as the specified object in the sort order.</summary>
<returns>A signed integer that indicates the relative position of this instance and <paramref name="other" /> in the sort order, as shown in the following table.
<list type="table"><listheader><term> Value
</term><description> Description
</description></listheader><item><term> A negative integer
</term><description> This instance precedes <paramref name="other" />.
</description></item><item><term> Zero
</term><description> This instance and <paramref name="other" /> have the same position in the sort order.
</description></item><item><term> A positive integer
</term><description> This instance follows <paramref name="other" />.
</description></item></list></returns>
<remarks>
<format type="text/markdown"><![CDATA[
## Remarks
This member is an explicit interface member implementation. It can be used only when the <xref:System.Tuple%605> instance is cast to an <xref:System.Collections.IStructuralComparable> interface.
Although this method can be called directly, it is most commonly called by collection-sorting methods that include <xref:System.Collections.IComparer> parameters to order the members of a collection. For example, it is called by the <xref:System.Array.Sort%28System.Array%2CSystem.Collections.IComparer%29?displayProperty=nameWithType> method and the <xref:System.Collections.SortedList.Add%2A> method of a <xref:System.Collections.SortedList> object that is instantiated by using the <xref:System.Collections.SortedList.%23ctor%28System.Collections.IComparer%29?displayProperty=nameWithType> constructor.
> [!CAUTION]
> The <xref:System.Tuple%605.System%23Collections%23IStructuralComparable%23CompareTo%2A> method is intended for use in sorting operations. It should not be used when the primary purpose of a comparison is to determine whether two objects are equal. To determine whether two objects are equal, call the <xref:System.Tuple%605.System%23Collections%23IStructuralEquatable%23Equals%28System.Object%2CSystem.Collections.IEqualityComparer%29> method.
## Examples
The following example creates an array of <xref:System.Tuple%605> objects that contain career statistical data for running backs in American professional football. The 5-tuple's components consist of the player's name, the number of games in which he played, the number of carries or attempts, the total number of yards gained, and the number of touchdowns scored. The example displays the components of each tuple in the array in unsorted order, sorts the array, and then calls <xref:System.Tuple%605.ToString%2A> to display each tuple in sorted order. To sort the array, the example defines a generic `YardsGained` class that implements the <xref:System.Collections.IComparer> interface and sorts the <xref:System.Tuple%605> objects in descending order by the value of their fourth component (yards gained) rather than by their first component. Note that the example does not directly call the <xref:System.Tuple%605.System%23Collections%23IStructuralComparable%23CompareTo%2A> method. This method is called implicitly by the <xref:System.Array.Sort%28System.Array%2CSystem.Collections.IComparer%29?displayProperty=nameWithType> method for each element in the array.
:::code language="csharp" source="~/snippets/csharp/System/TupleT1,T2,T3,T4,T5/System.Collections.IStructuralComparable.CompareTo/compareto2.cs" id="Snippet2":::
:::code language="fsharp" source="~/snippets/fsharp/System/TupleT1,T2,T3,T4,T5/System.Collections.IStructuralComparable.CompareTo/compareto2.fs" id="Snippet2":::
:::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.tuple`5.compareto/vb/compareto2.vb" id="Snippet2":::
]]></format>
</remarks>
<exception cref="T:System.ArgumentException">
<paramref name="other" /> is not a <see cref="T:System.Tuple`5" /> object.</exception>
</Docs>
</Member>
<Member MemberName="System.Collections.IStructuralEquatable.Equals">
<MemberSignature Language="C#" Value="bool IStructuralEquatable.Equals (object other, System.Collections.IEqualityComparer comparer);" />
<MemberSignature Language="ILAsm" Value=".method hidebysig newslot virtual instance bool System.Collections.IStructuralEquatable.Equals(object other, class System.Collections.IEqualityComparer comparer) cil managed" />
<MemberSignature Language="DocId" Value="M:System.Tuple`5.System#Collections#IStructuralEquatable#Equals(System.Object,System.Collections.IEqualityComparer)" />
<MemberSignature Language="VB.NET" Value="Function Equals (other As Object, comparer As IEqualityComparer) As Boolean Implements IStructuralEquatable.Equals" />
<MemberSignature Language="F#" Value="abstract member System.Collections.IStructuralEquatable.Equals : obj * System.Collections.IEqualityComparer -> bool
override this.System.Collections.IStructuralEquatable.Equals : obj * System.Collections.IEqualityComparer -> bool" Usage="tuple.System.Collections.IStructuralEquatable.Equals (other, comparer)" />
<MemberSignature Language="C++ CLI" Value=" virtual bool System.Collections.IStructuralEquatable.Equals(System::Object ^ other, System::Collections::IEqualityComparer ^ comparer) = System::Collections::IStructuralEquatable::Equals;" />
<MemberType>Method</MemberType>
<Implements>
<InterfaceMember>M:System.Collections.IStructuralEquatable.Equals(System.Object,System.Collections.IEqualityComparer)</InterfaceMember>
</Implements>
<AssemblyInfo>
<AssemblyName>System.Runtime</AssemblyName>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
<AssemblyVersion>4.0.10.0</AssemblyVersion>
<AssemblyVersion>4.0.20.0</AssemblyVersion>
<AssemblyVersion>4.1.0.0</AssemblyVersion>
<AssemblyVersion>4.2.0.0</AssemblyVersion>
<AssemblyVersion>4.2.1.0</AssemblyVersion>
<AssemblyVersion>4.2.2.0</AssemblyVersion>
<AssemblyVersion>5.0.0.0</AssemblyVersion>
<AssemblyVersion>6.0.0.0</AssemblyVersion>
<AssemblyVersion>7.0.0.0</AssemblyVersion>
<AssemblyVersion>8.0.0.0</AssemblyVersion>
<AssemblyVersion>9.0.0.0</AssemblyVersion>
</AssemblyInfo>
<AssemblyInfo>
<AssemblyName>mscorlib</AssemblyName>
<AssemblyVersion>2.0.5.0</AssemblyVersion>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
</AssemblyInfo>
<AssemblyInfo>
<AssemblyName>netstandard</AssemblyName>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
<AssemblyVersion>2.1.0.0</AssemblyVersion>
</AssemblyInfo>
<ReturnValue>
<ReturnType>System.Boolean</ReturnType>
</ReturnValue>
<Parameters>
<Parameter Name="other" Type="System.Object">
<Attributes>
<Attribute FrameworkAlternate="net-6.0;net-7.0;net-8.0;net-9.0">
<AttributeName Language="C#">[System.Diagnostics.CodeAnalysis.NotNullWhen(true)]</AttributeName>
<AttributeName Language="F#">[<System.Diagnostics.CodeAnalysis.NotNullWhen(true)>]</AttributeName>
</Attribute>
</Attributes>
</Parameter>
<Parameter Name="comparer" Type="System.Collections.IEqualityComparer" />
</Parameters>
<Docs>
<param name="other">The object to compare with this instance.</param>
<param name="comparer">An object that defines the method to use to evaluate whether the two objects are equal.</param>
<summary>Returns a value that indicates whether the current <see cref="T:System.Tuple`5" /> object is equal to a specified object based on a specified comparison method.</summary>
<returns>
<see langword="true" /> if the current instance is equal to the specified object; otherwise, <see langword="false" />.</returns>
<remarks>
<format type="text/markdown"><![CDATA[
## Remarks
This member is an explicit interface member implementation. It can be used only when the <xref:System.Tuple%605> instance is cast to an <xref:System.Collections.IStructuralEquatable> interface.
The <xref:System.Collections.IEqualityComparer.Equals%2A?displayProperty=nameWithType> implementation is called only if `other` is not `null`, and if it can be successfully cast (in C#) or converted (in Visual Basic) to a <xref:System.Tuple%605> object whose components are of the same types as the current instance. The <xref:System.Tuple%605.System%23Collections%23IStructuralEquatable%23Equals%28System.Object%2CSystem.Collections.IEqualityComparer%29> method first passes the <xref:System.Tuple%605.Item1%2A> values of the <xref:System.Tuple%605> objects to be compared to the <xref:System.Collections.IEqualityComparer.Equals%2A?displayProperty=nameWithType> implementation. If this method call returns `true`, the method is called again and passed the <xref:System.Tuple%605.Item2%2A> values of the two <xref:System.Tuple%605> objects. This continues until the method call returns `false` when it compares a specific pair of `Item` values, or the two <xref:System.Tuple%605.Item5%2A> values are passed to the method.
## Examples
The following example defines a `DoubleComparer` class that implements the <xref:System.Collections.IEqualityComparer> interface. The example instantiates two <xref:System.Tuple%605> objects by using a random number generator to populate their second through fifth components, casts the first instance to an <xref:System.Collections.IStructuralEquatable> interface, and then uses a `DoubleComparer` object to test the two <xref:System.Tuple%605> objects for approximate equality.
:::code language="csharp" source="~/snippets/csharp/System/TupleT1,T2,T3,T4,T5/Equals/equals2.cs" interactive="try-dotnet" id="Snippet2":::
:::code language="fsharp" source="~/snippets/fsharp/System/TupleT1,T2,T3,T4,T5/Equals/equals2.fs" id="Snippet2":::
:::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.tuple`5.equals/vb/equals2.vb" id="Snippet2":::
]]></format>
</remarks>
</Docs>
</Member>
<Member MemberName="System.Collections.IStructuralEquatable.GetHashCode">
<MemberSignature Language="C#" Value="int IStructuralEquatable.GetHashCode (System.Collections.IEqualityComparer comparer);" />
<MemberSignature Language="ILAsm" Value=".method hidebysig newslot virtual instance int32 System.Collections.IStructuralEquatable.GetHashCode(class System.Collections.IEqualityComparer comparer) cil managed" />
<MemberSignature Language="DocId" Value="M:System.Tuple`5.System#Collections#IStructuralEquatable#GetHashCode(System.Collections.IEqualityComparer)" />
<MemberSignature Language="VB.NET" Value="Function GetHashCode (comparer As IEqualityComparer) As Integer Implements IStructuralEquatable.GetHashCode" />
<MemberSignature Language="F#" Value="abstract member System.Collections.IStructuralEquatable.GetHashCode : System.Collections.IEqualityComparer -> int
override this.System.Collections.IStructuralEquatable.GetHashCode : System.Collections.IEqualityComparer -> int" Usage="tuple.System.Collections.IStructuralEquatable.GetHashCode comparer" />
<MemberSignature Language="C++ CLI" Value=" virtual int System.Collections.IStructuralEquatable.GetHashCode(System::Collections::IEqualityComparer ^ comparer) = System::Collections::IStructuralEquatable::GetHashCode;" />
<MemberType>Method</MemberType>
<Implements>
<InterfaceMember>M:System.Collections.IStructuralEquatable.GetHashCode(System.Collections.IEqualityComparer)</InterfaceMember>
</Implements>
<AssemblyInfo>
<AssemblyName>System.Runtime</AssemblyName>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
<AssemblyVersion>4.0.10.0</AssemblyVersion>
<AssemblyVersion>4.0.20.0</AssemblyVersion>
<AssemblyVersion>4.1.0.0</AssemblyVersion>
<AssemblyVersion>4.2.0.0</AssemblyVersion>
<AssemblyVersion>4.2.1.0</AssemblyVersion>
<AssemblyVersion>4.2.2.0</AssemblyVersion>
<AssemblyVersion>5.0.0.0</AssemblyVersion>
<AssemblyVersion>6.0.0.0</AssemblyVersion>
<AssemblyVersion>7.0.0.0</AssemblyVersion>
<AssemblyVersion>8.0.0.0</AssemblyVersion>
<AssemblyVersion>9.0.0.0</AssemblyVersion>
</AssemblyInfo>
<AssemblyInfo>
<AssemblyName>mscorlib</AssemblyName>
<AssemblyVersion>2.0.5.0</AssemblyVersion>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
</AssemblyInfo>
<AssemblyInfo>
<AssemblyName>netstandard</AssemblyName>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
<AssemblyVersion>2.1.0.0</AssemblyVersion>
</AssemblyInfo>
<ReturnValue>
<ReturnType>System.Int32</ReturnType>
</ReturnValue>
<Parameters>
<Parameter Name="comparer" Type="System.Collections.IEqualityComparer" />
</Parameters>
<Docs>
<param name="comparer">An object whose <see cref="M:System.Collections.IEqualityComparer.GetHashCode(System.Object)" /> method calculates the hash code of the current <see cref="T:System.Tuple`5" /> object.</param>
<summary>Calculates the hash code for the current <see cref="T:System.Tuple`5" /> object by using a specified computation method.</summary>
<returns>A 32-bit signed integer hash code.</returns>
<remarks>
<format type="text/markdown"><![CDATA[
## Remarks
This member is an explicit interface member implementation. It can be used only when the <xref:System.Tuple%605> instance is cast to an <xref:System.Collections.IStructuralEquatable> interface.
The method simply wraps a call to the `comparer` object's <xref:System.Collections.IEqualityComparer.GetHashCode%2A?displayProperty=nameWithType> implementation.
The algorithm used to compute the hash code should return the same hash code for two <xref:System.Tuple%605> objects that are considered to be equal.
]]></format>
</remarks>
</Docs>
</Member>
<Member MemberName="System.IComparable.CompareTo">
<MemberSignature Language="C#" Value="int IComparable.CompareTo (object obj);" />
<MemberSignature Language="ILAsm" Value=".method hidebysig newslot virtual instance int32 System.IComparable.CompareTo(object obj) cil managed" />
<MemberSignature Language="DocId" Value="M:System.Tuple`5.System#IComparable#CompareTo(System.Object)" />
<MemberSignature Language="VB.NET" Value="Function CompareTo (obj As Object) As Integer Implements IComparable.CompareTo" />
<MemberSignature Language="F#" Value="abstract member System.IComparable.CompareTo : obj -> int
override this.System.IComparable.CompareTo : obj -> int" Usage="tuple.System.IComparable.CompareTo obj" />
<MemberSignature Language="C++ CLI" Value=" virtual int System.IComparable.CompareTo(System::Object ^ obj) = IComparable::CompareTo;" />
<MemberType>Method</MemberType>
<Implements>
<InterfaceMember>M:System.IComparable.CompareTo(System.Object)</InterfaceMember>
</Implements>
<AssemblyInfo>
<AssemblyName>System.Runtime</AssemblyName>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
<AssemblyVersion>4.0.10.0</AssemblyVersion>
<AssemblyVersion>4.0.20.0</AssemblyVersion>
<AssemblyVersion>4.1.0.0</AssemblyVersion>
<AssemblyVersion>4.2.0.0</AssemblyVersion>
<AssemblyVersion>4.2.1.0</AssemblyVersion>
<AssemblyVersion>4.2.2.0</AssemblyVersion>
<AssemblyVersion>5.0.0.0</AssemblyVersion>
<AssemblyVersion>6.0.0.0</AssemblyVersion>
<AssemblyVersion>7.0.0.0</AssemblyVersion>
<AssemblyVersion>8.0.0.0</AssemblyVersion>
<AssemblyVersion>9.0.0.0</AssemblyVersion>
</AssemblyInfo>
<AssemblyInfo>
<AssemblyName>mscorlib</AssemblyName>
<AssemblyVersion>2.0.5.0</AssemblyVersion>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
</AssemblyInfo>
<AssemblyInfo>
<AssemblyName>netstandard</AssemblyName>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
<AssemblyVersion>2.1.0.0</AssemblyVersion>
</AssemblyInfo>
<ReturnValue>
<ReturnType>System.Int32</ReturnType>
</ReturnValue>
<Parameters>
<Parameter Name="obj" Type="System.Object" />
</Parameters>
<Docs>
<param name="obj">An object to compare with the current instance.</param>
<summary>Compares the current <see cref="T:System.Tuple`5" /> object to a specified object and returns an integer that indicates whether the current object is before, after, or in the same position as the specified object in the sort order.</summary>
<returns>A signed integer that indicates the relative position of this instance and <paramref name="obj" /> in the sort order, as shown in the following table.
<list type="table"><listheader><term> Value
</term><description> Description
</description></listheader><item><term> A negative integer
</term><description> This instance precedes <paramref name="obj" />.
</description></item><item><term> Zero
</term><description> This instance and <paramref name="obj" /> have the same position in the sort order.
</description></item><item><term> A positive integer
</term><description> This instance follows <paramref name="obj" />.
</description></item></list></returns>
<remarks>
<format type="text/markdown"><![CDATA[
## Remarks
This member is an explicit interface member implementation. It can be used only when the <xref:System.Tuple%605> instance is cast to an <xref:System.IComparable> interface.
This method provides the <xref:System.IComparable.CompareTo%2A?displayProperty=nameWithType> implementation for the <xref:System.Tuple%605> class. Although the method can be called directly, it is most commonly called by the default overloads of collection-sorting methods, such as <xref:System.Array.Sort%28System.Array%29?displayProperty=nameWithType> and <xref:System.Collections.SortedList.Add%2A?displayProperty=nameWithType>, to order the members of a collection.
> [!CAUTION]
> The <xref:System.Tuple%605.System%23IComparable%23CompareTo%2A> method is intended for use in sorting operations. It should not be used when the primary purpose of a comparison is to determine whether two objects are equal. To determine whether two objects are equal, call the <xref:System.Tuple%605.Equals%28System.Object%29?displayProperty=nameWithType> method.
The <xref:System.Tuple%605.System%23IComparable%23CompareTo%28System.Object%29> method uses the default object comparer to compare each component.
## Examples
The following example creates an array of <xref:System.Tuple%605> objects that contain career statistics for running backs in American professional football. The five components consist of the player's name, the number of games in which he played, the number of carries or attempts, the total number of yards gained, and the number of touchdowns scored. The example displays the components of each tuple in the array in unsorted order, sorts the array, and then calls <xref:System.Tuple%605.ToString%2A> to display each tuple in sorted order. The output shows that the array has been sorted by name, which is the first component. Note that the example does not directly call the <xref:System.Tuple%605.System%23IComparable%23CompareTo%2A> method. This method is called implicitly by the <xref:System.Array.Sort%28System.Array%29> method for each element in the array.
:::code language="csharp" source="~/snippets/csharp/System/TupleT1,T2,T3,T4,T5/System.Collections.IStructuralComparable.CompareTo/compareto1.cs" id="Snippet1":::
:::code language="fsharp" source="~/snippets/fsharp/System/TupleT1,T2,T3,T4,T5/System.Collections.IStructuralComparable.CompareTo/compareto1.fs" id="Snippet1":::
:::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.tuple`5.compareto/vb/compareto1.vb" id="Snippet1":::
]]></format>
</remarks>
<exception cref="T:System.ArgumentException">
<paramref name="obj" /> is not a <see cref="T:System.Tuple`5" /> object.</exception>
<altmember cref="M:System.Tuple`5.Equals(System.Object)" />
</Docs>
</Member>
<Member MemberName="System.Runtime.CompilerServices.ITuple.Item">
<MemberSignature Language="C#" Value="object? System.Runtime.CompilerServices.ITuple.Item[int index] { get; }" FrameworkAlternate="net-5.0;net-6.0;net-7.0;net-8.0;net-9.0;netcore-3.0;netcore-3.1;netframework-4.7.1-pp;netframework-4.7.2-pp;netframework-4.7-pp;netframework-4.8.1-pp;netframework-4.8-pp" />
<MemberSignature Language="ILAsm" Value=".property instance object System.Runtime.CompilerServices.ITuple.Item(int32)" />
<MemberSignature Language="DocId" Value="P:System.Tuple`5.System#Runtime#CompilerServices#ITuple#Item(System.Int32)" />
<MemberSignature Language="VB.NET" Value=" ReadOnly Property Item(index As Integer) As Object Implements ITuple.Item" />
<MemberSignature Language="F#" Value="member this.System.Runtime.CompilerServices.ITuple.Item(int) : obj" Usage="System.Runtime.CompilerServices.ITuple.Item" />
<MemberSignature Language="C++ CLI" Value="property System::Object ^ System::Runtime::CompilerServices::ITuple::Item[int] { System::Object ^ get(int index); };" />
<MemberSignature Language="C#" Value="object System.Runtime.CompilerServices.ITuple.Item[int index] { get; }" FrameworkAlternate="netcore-2.0;netcore-2.1;netcore-2.2;netframework-4.7.1;netframework-4.7.2;netframework-4.8;netframework-4.8.1;netstandard-2.1" />
<MemberType>Property</MemberType>
<Implements>
<InterfaceMember>P:System.Runtime.CompilerServices.ITuple.Item(System.Int32)</InterfaceMember>
</Implements>
<AssemblyInfo>
<AssemblyName>System.Runtime</AssemblyName>
<AssemblyVersion>4.2.0.0</AssemblyVersion>
<AssemblyVersion>4.2.1.0</AssemblyVersion>
<AssemblyVersion>4.2.2.0</AssemblyVersion>
<AssemblyVersion>5.0.0.0</AssemblyVersion>
<AssemblyVersion>6.0.0.0</AssemblyVersion>
<AssemblyVersion>7.0.0.0</AssemblyVersion>
<AssemblyVersion>8.0.0.0</AssemblyVersion>
<AssemblyVersion>9.0.0.0</AssemblyVersion>
</AssemblyInfo>